package net.zjitc.utils;

import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.UUID;

/**
 * Created by Administrator on 2017/11/23.
 */
public class CommonUtils {
    public static String uuid(){
        return UUID.randomUUID().toString().replace("-","");
    }
    //将日期转为字符串
    public static String dateToString(Date date){
        SimpleDateFormat sf=new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
        return sf.format(date);
    }
}













